{include file="top.html"}
<link rel="stylesheet" href="/style/mobile/css_02/font/iconfont.css">
<link rel="stylesheet" href="/style/mobile/css/bootstrap.css">
<link rel="stylesheet" href="/style/mobile/css/new_index.css">
<link rel="stylesheet" href="/style/mobile/css_02/index.css">
<script src="/js/lefttime.js"></script>
<script src="/js/lefttime_jx.js"></script>
<style type="text/css">
    *{ box-sizing: border-box; }
</style>
<header id="header" style="display: none;">
    <a href="{url()}" class="logo"><img src="{zz mod=fileurl source=$site_config.mobile_logo}" /></a>
    <div class="u-nav">
        <a class="ap-icon" href="/yunbuy"><img src="/style/mobile/images/search2.png" /></a>
    </div>
</header>
{if $wechat && $subscribe}
<dl class="subscribe">
    <dt>
        <button id="btn_subscribe">立即关注</button>
        <p>欢迎进入<span>{$site_config.site_name}</span><br>关注公众号，享专属服务</p>
    </dt>
    <dd>
        <p class="p1"><img src="{zz mod=fileurl source=$site_config.weixin_logo}" /></p>
        <p class="p2">长按二维码图片，识别图中二维码 关注</p>
        <p class="p3">关注我们 获取更多服务</p>
    </dd>
</dl>
<script type="text/javascript">
    $(function(){
        $('#btn_subscribe').click(function(){
            $('.subscribe').toggleClass('subscribe_toggle');
            if($('.subscribe').hasClass('subscribe_toggle')){
                $(this).html('关闭');
            }else{
                $(this).html('立即关注');
            }
        })
    })
</script>
{/if}
<div class="new_banner" id="new_banner">
    <div class="slider">
        {zz mod=content var=tagAdw module=ad id=10}
        {zz mod=fileurl var=tagAds source=$tagAdw.images num=10}
        {foreach from=$tagAds item=m}
        <div><a href="{$m.title}"{if $m.isblank} target="_blank"{/if}><img src="{$m.path}"/></a></div>
        {/foreach}
    </div>
    <ul class="slick-dots">
        {foreach from=$tagAds item=m}
        <li><button type="button"></button></li>
        {/foreach}
    </ul>
</div>
<div class="menu">
    <div class="slider">
        {foreach from=$mobileCat item=m}
        <div>
            <a href="{$m.url}">
                <em><img src="{$m.pic}" /></em>
                <p>{$m.catname}</p>
            </a>
        </div>
        {/foreach}
    </div>
</div>
<div class="new-index">
    <div class="new-index-top"><a href="{'/content/win'|url}">最新揭晓</a></div>
    <ul class="new-index-1" id="win-list">
        {foreach from=$luck_db item=m name=list}
        {include file="content/windbitemindex.html"}
        {/foreach}
        <input type="hidden" name="ids" id="ids" value="" />
    </ul>
</div>
<div class="new-inex1 demo" id="buy_nav">
    <ul class="new-index1-top">
        <li onclick="location.href='?order=ratio&sort=desc#buy_nav'" {if $smarty.get.order eq 'ratio' || !$smarty.get.order}class="hover"{/if}>最快</li>
        <li onclick="location.href='?order=end_num&sort=asc#buy_nav'" {if $smarty.get.order eq 'end_num'}class="hover"{/if}>最热</li>
        <li onclick="location.href='?order=buy_id&sort=desc#buy_nav'" {if $smarty.get.order eq 'buy_id'}class="hover"{/if}>最新</li>
        <li onclick="location.href='?order=need_num&sort=asc#buy_nav'" {if $smarty.get.order eq 'need_num' && $smarty.get.sort eq 'asc'}class="hover"{/if}>价格<i class="iconfont">&#xe609;</i></li>
        <li onclick="location.href='?order=need_num&sort=desc#buy_nav'" {if $smarty.get.order eq 'need_num' && $smarty.get.sort eq 'desc'}class="hover"{/if}>价格<i class="iconfont">&#xe608;</i></li>
    </ul>
    <div id="container" class="clearfix new-index2 list">
        {include file="yunbuy/lbi/list2.html"}
    </div>
</div>
<script type="text/javascript">
    var order = "{if $smarty.get.order}{$smarty.get.order}{else}ratio{/if}";
    var sort = "{if $smarty.get.sort}{$smarty.get.sort}{else}desc{/if}";
    var ExtendOptions = {
        itemSelector: 'div.new-box',
        path: function(index) {
            return "/yunbuy/index/"+index+"?order="+order+"&sort="+sort+"&load&skin=2&size={$size}";
        }
    };
</script>
{include file="public_scroll.html"}

{include file="footer.html"}
<script src="/style/TouchSlide.1.1.js"></script>
<script type="text/javascript">
    $(document).ready(function(){
        compaceIds();
        setInterval('compaceIds()',5*1000);
    });
    function compaceIds(){
        $.post('/content/ajaxIds','skin=index_mobile&ids='+$('#ids').val(),function(data){
            if(data.error==1){
                $('#ids').val(data.ids);
                $('#win-list').prepend(data.html);
            }
        },'json');
    }
</script>
<script>
    TouchSlide({ slideCell:"#new_banner", mainCell:".slider", titCell:".slick-dots li", titOnClassName:"slick-active", autoPlay:true, interTime:5000 });
    $(".new-index-1 li:odd").addClass("new-odd")
</script>
{literal}
<script type="text/javascript" src="/style/mobile/js/slick.min.js"></script>
<script type="text/javascript">
    $(document).ready(function(){
        $(".new-index2 .new-box:odd").addClass("new-nr")
        $('.menu .slider').slick({
            autoplay: true,
            dots:true,
            arrows:false,
            slidesToShow: 5,
            slidesToScroll:5,
            responsive: [
                {
                    breakpoint:480,
                    settings: {
                        autoplay:true,
                        arrows:false,
                        dots:true,
                        slidesToShow: 4,
                        slidesToScroll:4
                    }
                }
            ]
        });
    });
</script>
{/literal}